<template>
  <zm-view background="#F4F6F7" scroll>
    <view v-for="(item, index) in list" :key="index" class="mx-24 mt-20 p-24 b radius-16 bg-white flex" @click="handleClickPerformer(item, index)">
      <u-image width="152rpx" height="206rpx" radius="12rpx" :src="item.headImg"></u-image>
      <view class="flex flex-col py-28 ml-24">
        <text class="font-28 font-700">{{ item.actorName }}</text>
        <text class="text-999 mt-8">{{ item.roleName }}</text>
      </view>
    </view>
  </zm-view>
</template>

<script>
import page from "@/mixins/page"
export default {
  mixins: [page],
  data() {
    return {
      list: []
    }
  },
  onLoad() {
    this.list = uni.$getCache("performer-list")
  },
  methods: {
    // 点击演员
    handleClickPerformer(data, index) {
      uni.previewImage({
        current: index,
        urls: this.list.map((item) => item.headImg)
      })
    }
  }
}
</script>

<style lang="scss" scoped></style>
